﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Results.aspx.cs" Inherits="KnowFirstWebApplication.Results" MasterPageFile="~/Site1.Master" EnableSessionState="ReadOnly"  %>

<asp:Content runat="server" ContentPlaceHolderID="ContentPlaceHolder1" ID="ResultsContent">

    <div id="CategoriesTitle" style="vertical-align: middle; text-align: right" >
    <h3 dir="rtl" style="color: #996633" >תוצאות:</h3>
    </div>
    <div style="direction: rtl">
    
    <table class="style1">
        <tr>
            <td class="style2">
    	<asp:ListBox id="lbCategories" runat="server" Width="180px" Height="110px">
		</asp:ListBox><br />
		
		    </td>
        </tr>
    </table>
    </div>
    <div id="pre-results" style="margin-top: 20px; margin-bottom: 20px" dir="rtl"  >
     <asp:CheckBoxList runat="server" id="cblDocumentTypes" RepeatDirection="Horizontal" 
                    Height="16px" Width="315px" 
            onselectedindexchanged="cblDocumentTypes_SelectedIndexChanged" 
            AutoPostBack="True"></asp:CheckBoxList>
            <span id="dateSelect"  
            style="vertical-align: middle; word-spacing: 0.5em; line-height: normal;">
        <asp:Label ID="Label1" runat="server" Text=" מתאריך "></asp:Label>
        <asp:DropDownList ID="cbFromYear" runat="server"/>
        <asp:DropDownList ID="cbFromMonth" runat="server"/>
        <asp:DropDownList ID="cbFromDay" runat="server"/>
        <asp:Label ID="Label2" runat="server" Text=" עד "></asp:Label>
        <asp:DropDownList ID="cbToYear" runat="server"/>
        <asp:DropDownList ID="cbToMonth" runat="server"/>
        <asp:DropDownList ID="cbToDay" runat="server"/>
		
		<asp:Button id="btnLoadCategory" runat="server" Text="הצג תוצאות" 
            onclick="btnLoadCategory_Click" Width="121px" 
                   />
        </span>
        <br /><br />
    <asp:Label ID="lblCategoryName" runat="server"></asp:Label>
    
    </div>
    <div id="results" dir="rtl" >
    
        <asp:ListView ID="lvCategoryResults" runat="server" OnPagePropertiesChanging="lvCategoryResults_PagePropertiesChanging">
        <LayoutTemplate>
        <span id="itemPlaceholder" runat="server"></span>
        <table id="groupPlaceholder" runat="server">
</table>

        </LayoutTemplate>
        <ItemTemplate>
        <span id="datetime"> <%# Eval("DateTime") %> </span> - <asp:Label runat="server" ID="lblDocType"> <%# Common.Document.DocumentTypeToString((Common.Document.Type)Eval("DocType")) %> </asp:Label>
          <br />
         <span id="talkbackNumber" > <%# ((int)Eval("talkbackNumber") > 0) ? Eval("talkbackNumber") : "" %> </span> - <asp:HyperLink runat="server" ID="TitleHyperLink" Text='<%#(((string)Eval("Title")).Length < 2)? "ללא כותרת" : Eval("Title") %>' NavigateUrl='<%# Eval("url") %>'>   </asp:HyperLink>
          <br /> 
        <%# Notifying.HTMLBuilder.ArrangeExcerpts(Eval("excerpts") as string[]) %> 
         <span  style="color: Green">  <%#Eval("DisplayNameProperty") %> - <asp:Label runat="server" Text='<%# Eval("Url") %>' > </asp:Label>  </span> 
       
        </ItemTemplate>
        <ItemSeparatorTemplate>
        <br /><br />
        </ItemSeparatorTemplate>
        </asp:ListView>
        
        <br />
        <div id="pager"  style="text-align: center" dir="ltr">
    <asp:DataPager runat="server" ID="ResultsDataPager" PagedControlID="lvCategoryResults" PageSize="20">
<Fields>
<asp:NumericPagerField  NextPageText=">" PreviousPageText="<" /> 
</Fields>
</asp:DataPager>
</div>
    
</div>

</asp:Content>